package com.example.spring.dao;

import javax.transaction.Transactional;

/**
 * 产品DAO - 没有接口的实现
 */
public class ProductDao {
    private String dataSource;

    public ProductDao(String dataSource) {
        this.dataSource = dataSource;
    }

    public void saveProduct(String productName) {
        System.out.println("保存产品[" + dataSource + "]: " + productName);
    }

    @Transactional
    public void updateProduct(String productName) {
        System.out.println("更新产品[" + dataSource + "]: " + productName);
    }
}
